﻿using System;
using Microsoft.Xna.Framework;

namespace PoolGame2.Physics
{
    class PhysicsConstants
    {
        public static float DEFAULT_RADIUS = 4.949f / 2f;
        public static float DEFAULT_RADIUS_SQUARED = DEFAULT_RADIUS * DEFAULT_RADIUS;
        public static float DEFAULT_CIRCUMFERENCE = (float)(Math.PI * DEFAULT_RADIUS * 2);
        public static float MASS = 0.17f;
        public static float INVERSE_MASS = 1.0f / MASS;
        public static float MOMENT_OF_INTERIA = 2.0f / 5.0f * MASS * DEFAULT_RADIUS_SQUARED;
        public static float INVERSE_MOMENT_OF_INTERIA = 1.0f / MOMENT_OF_INTERIA;
        
        public static float MIN_VELOCITY = 0.02f;
        public static float DAMPING = 1f;
        public static float SPRING_CONSTANT = 10f;
        public static float CUE_CONTACT_TIME = 0.01f;
        public static float COEFFICIENT_OF_SLIDING_FRICTION = 0.64f;
        public static float GRAVITY = 9.8f;
        public static float BALL_CUSHION_ELASTICITY_COEFFICIANT = 0.93f;
        public static float BALL_BALL_ELASTICITY_COEFFICIANT = 0.98f;
        public static float INTEGRATE_FRICTION_BY_GRAVITY = -COEFFICIENT_OF_SLIDING_FRICTION * GRAVITY;
        public static float INTEGRATE_OMEGA_MULTIPLYER = INTEGRATE_FRICTION_BY_GRAVITY * MASS * DEFAULT_RADIUS;
        public static float TRACK_FORWARD_TIME = 5f;
        public static float POCKET_RADIUS = 10;
        
        public static Vector3 INTEGRATE_R = new Vector3(0.0f, -DEFAULT_RADIUS, 0.0f);

        public static Vector3 POCKET_TOP_LEFT = new Vector3(74.5f, 50.0f, -47.0f);
        public static Vector3 POCKET_TOP_RIGHT = new Vector3(74.5f, 50.0f, 35.5f);
        public static Vector3 POCKET_CENTER_LEFT = new Vector3(-3.5f, 50.0f, -47.0f);
        public static Vector3 POCKET_CENTER_RIGHT = new Vector3(-3.5f, 50.0f, 35.5f);
        public static Vector3 POCKET_BOTTOM_LEFT = new Vector3(-81.5f, 50.0f, -47.0f);
        public static Vector3 POCKET_BOTTOM_RIGHT = new Vector3(-81.5f, 50.0f, 35.5f);


        public static Vector3 CUSHION_TOP_START = new Vector3(74.85093f, 54f, -40.73975f);
        public static Vector3 CUSHION_TOP_MAIN_START = new Vector3(71.69004f, 54f, -38.96001f);
        public static Vector3 CUSHION_TOP_MAIN_END = new Vector3(71.61002f,54f,27.65001f);
        public static Vector3 CUSHION_TOP_END = new Vector3(74.79996f, 54f, 29.96f);

        public static Vector3 CUSHION_TOP_LEFT_START = new Vector3(2.03f,54f,-46.79987f);
        public static Vector3 CUSHION_TOP_LEFT_MAIN_START = new Vector3(3.11f,54f,-42.83003f);
        public static Vector3 CUSHION_TOP_LEFT_MAIN_END = new Vector3(66.88976f,54f,-42.83003f);
        public static Vector3 CUSHION_TOP_LEFT_END = new Vector3(69.41009f,54f,-46.89985f);

        public static Vector3 CUSHION_BOTTOM_LEFT_START = new Vector3(-76.33028f,54f,-46.96968f);
        public static Vector3 CUSHION_BOTTOM_LEFT_MAIN_START = new Vector3(-73.29996f, 54f, -43f);
        public static Vector3 CUSHION_BOTTOM_LEFT_MAIN_END = new Vector3(-9.969999f, 54f, -42.97001f);
        public static Vector3 CUSHION_BOTTOM_LEFT_END = new Vector3(-9.480011f,54f,-46.88002f);

        public static Vector3 CUSHION_BOTTOM_START = new Vector3(-82.12003f, 54f, 29.40001f);
        public static Vector3 CUSHION_BOTTOM_MAIN_START = new Vector3(-78.83007f, 54f, 26.55999f);
        public static Vector3 CUSHION_BOTTOM_MAIN_END = new Vector3(-78.5f, 54f, -38.34011f);
        public static Vector3 CUSHION_BOTTOM_END = new Vector3(-82.3205f, 54f, -40.93984f);
        
        public static Vector3 CUSHION_BOTTOM_RIGHT_START = new Vector3(-9.310007f, 54f, 35.62989f);
        public static Vector3 CUSHION_BOTTOM_RIGHT_MAIN_START = new Vector3(-9.760017f, 54f, 32.32003f);
        public static Vector3 CUSHION_BOTTOM_RIGHT_MAIN_END = new Vector3(-74.9602f, 54f, 32.25004f);
        public static Vector3 CUSHION_BOTTOM_RIGHT_END = new Vector3(-76.14024f, 54f, 35.46975f);

        public static Vector3 CUSHION_TOP_RIGHT_START = new Vector3(69.24005f, 54f, 35.46992f);
        public static Vector3 CUSHION_TOP_RIGHT_MAIN_START = new Vector3(66.79974f, 54f, 32.23005f);
        public static Vector3 CUSHION_TOP_RIGHT_MAIN_END = new Vector3(2.59f, 54, 32.19005f);
        public static Vector3 CUSHION_TOP_RIGHT_END = new Vector3(1.99f, 54f, 35.65989f);
        

    }
}
